<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>

<div id="app">
    <a v-bind:href="url">百度一下你就知道</a>

    <a v-on:click="doSomething">点击发生一些事</a>
</div>

<script src="../js/vue.js"></script>
<script>
    var app = new Vue({
        el: '#app',
        data: {
            url: 'https://www.baidu.com'
        },
        methods: {
            doSomething(){
                console.log('发生吧！')
            }
        }
    })
</script>
</body>
</html>